import request from '@/router/axios';

export const getList = (params) => {
  return request({
    url: '/api/mes-admin/area/page-of-part-storage-manage',
    method: 'get',
    params: {
      ...params
    }
  });
};

export const detail = (current, size, params) => {
  return request({
    url: '/api/mes-admin/area/detail',
    method: 'get',
    params: {
      current,
      size,
      params
    }
  });
};

export const getMaterialCategory = (params) => {
  return request({
    url: '/api/mes-admin/part-category/lazy-list',
    method: 'get',
    params: {
      ...params
    }
  });
};

export const getMaterial = (params) => {
  return request({
    url: '/api/mes-admin/part-master/page',
    method: 'get',
    params: {
      ...params
    }
  });
};

export const getExprot = (data) => {
  return request({
    url: '/api/mes-admin/area/import-part-storage-setting-templated',
    method: 'GET',
    responseType: 'blob'
  });
};
